Optimal. Leaf size=61 \[ -\frac {c^3}{a x}+\frac {d^3 x}{b}-\frac {c^2 (b c-3 a d) \log (x)}{a^2}+\frac {(b c-a d)^3 \log (a+b x)}{a^2 b^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.03, antiderivative size = 61, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 1, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.056, Rules used = {90}
\begin {gather*} \frac {(b c-a d)^3 \log (a+b x)}{a^2 b^2}-\frac {c^2 \log (x) (b c-3 a d)}{a^2}-\frac {c^3}{a x}+\frac {d^3 x}{b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 90
Rubi steps
\begin {align*} \int \frac {(c+d x)^3}{x^2 (a+b x)} \, dx &=\int \left (\frac {d^3}{b}+\frac {c^3}{a x^2}+\frac {c^2 (-b c+3 a d)}{a^2 x}-\frac {(-b c+a d)^3}{a^2 b (a+b x)}\right ) \, dx\\ &=-\frac {c^3}{a x}+\frac {d^3 x}{b}-\frac {c^2 (b c-3 a d) \log (x)}{a^2}+\frac {(b c-a d)^3 \log (a+b x)}{a^2 b^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.03, size = 66, normalized size = 1.08 \begin {gather*} \frac {a b \left (-b c^3+a d^3 x^2\right )+b^2 c^2 (-b c+3 a d) x \log (x)+(b c-a d)^3 x \log (a+b x)}{a^2 b^2 x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.07, size = 88, normalized size = 1.44
method | result | size |
default | \(\frac {d^{3} x}{b}+\frac {\left (-a^{3} d^{3}+3 a^{2} b c \,d^{2}-3 a \,b^{2} c^{2} d +b^{3} c^{3}\right ) \ln \left (b x +a \right )}{b^{2} a^{2}}-\frac {c^{3}}{a x}+\frac {c^{2} \left (3 a d -b c \right ) \ln \left (x \right )}{a^{2}}\) | \(88\) |
norman | \(\frac {\frac {d^{3} x^{2}}{b}-\frac {c^{3}}{a}}{x}+\frac {c^{2} \left (3 a d -b c \right ) \ln \left (x \right )}{a^{2}}-\frac {\left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) \ln \left (b x +a \right )}{b^{2} a^{2}}\) | \(93\) |
risch | \(\frac {d^{3} x}{b}-\frac {c^{3}}{a x}+\frac {3 c^{2} \ln \left (-x \right ) d}{a}-\frac {c^{3} \ln \left (-x \right ) b}{a^{2}}-\frac {a \ln \left (b x +a \right ) d^{3}}{b^{2}}+\frac {3 \ln \left (b x +a \right ) c \,d^{2}}{b}-\frac {3 \ln \left (b x +a \right ) c^{2} d}{a}+\frac {b \ln \left (b x +a \right ) c^{3}}{a^{2}}\) | \(106\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.30, size = 89, normalized size = 1.46 \begin {gather*} \frac {d^{3} x}{b} - \frac {c^{3}}{a x} - \frac {{\left (b c^{3} - 3 \, a c^{2} d\right )} \log \left (x\right )}{a^{2}} + \frac {{\left (b^{3} c^{3} - 3 \, a b^{2} c^{2} d + 3 \, a^{2} b c d^{2} - a^{3} d^{3}\right )} \log \left (b x + a\right )}{a^{2} b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 1.13, size = 98, normalized size = 1.61 \begin {gather*} \frac {a^{2} b d^{3} x^{2} - a b^{2} c^{3} + {\left (b^{3} c^{3} - 3 \, a b^{2} c^{2} d + 3 \, a^{2} b c d^{2} - a^{3} d^{3}\right )} x \log \left (b x + a\right ) - {\left (b^{3} c^{3} - 3 \, a b^{2} c^{2} d\right )} x \log \left (x\right )}{a^{2} b^{2} x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 196 vs.
\(2 (53) = 106\).
time = 0.73, size = 196, normalized size = 3.21 \begin {gather*} \frac {d^{3} x}{b} - \frac {c^{3}}{a x} + \frac {c^{2} \cdot \left (3 a d - b c\right ) \log {\left (x + \frac {3 a^{2} b c^{2} d - a b^{2} c^{3} - a b c^{2} \cdot \left (3 a d - b c\right )}{a^{3} d^{3} - 3 a^{2} b c d^{2} + 6 a b^{2} c^{2} d - 2 b^{3} c^{3}} \right )}}{a^{2}} - \frac {\left (a d - b c\right )^{3} \log {\left (x + \frac {3 a^{2} b c^{2} d - a b^{2} c^{3} + \frac {a \left (a d - b c\right )^{3}}{b}}{a^{3} d^{3} - 3 a^{2} b c d^{2} + 6 a b^{2} c^{2} d - 2 b^{3} c^{3}} \right )}}{a^{2} b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 1.22, size = 91, normalized size = 1.49 \begin {gather*} \frac {d^{3} x}{b} - \frac {c^{3}}{a x} - \frac {{\left (b c^{3} - 3 \, a c^{2} d\right )} \log \left ({\left | x \right |}\right )}{a^{2}} + \frac {{\left (b^{3} c^{3} - 3 \, a b^{2} c^{2} d + 3 \, a^{2} b c d^{2} - a^{3} d^{3}\right )} \log \left ({\left | b x + a \right |}\right )}{a^{2} b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.42, size = 88, normalized size = 1.44 \begin {gather*} \frac {d^3\,x}{b}-\frac {c^3}{a\,x}+\frac {c^2\,\ln \left (x\right )\,\left (3\,a\,d-b\,c\right )}{a^2}-\frac {\ln \left (a+b\,x\right )\,\left (a^3\,d^3-3\,a^2\,b\,c\,d^2+3\,a\,b^2\,c^2\,d-b^3\,c^3\right )}{a^2\,b^2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________